interface ISay {
  say():void;
}

class EngSay implements ISay {
    say() {
        console.log("hello");
    }
}


class ChsSay implements ISay {
  say() {
      console.log("您好");
  }
}

function callSay(sayIns:ISay):void {
  console.log("in callSay");
  sayIns.say();
}

let chsIns = new ChsSay;
let engIns = new EngSay;

callSay(chsIns);
callSay(engIns);
